From: Florian Müllner Date: Sat, 9 Feb 2013 22:05:43 +0000 (+0100) Subject: grabHelper: Restore the actually saved focus on ungrab X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~1013^2^2~4889 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=60257f422a5a35cee2adbcbc0d94738bc2e2fb9d;p=gnome-shell.git grabHelper: Restore the actually saved focus on ungrab GrabHelper saves the actor that had key focus when taking over the grab (if any). On ungrab, the key focus is either restored or moved to some child of the saved actor. The latter is unexpected and causes some odd behavior, so don't be fancy and only restore the actual focus. https://bugzilla.gnome.org/show_bug.cgi?id=693570 --- diff --git a/js/ui/grabHelper.js b/js/ui/grabHelper.js index 315e2d49b..fe3a121ce 100644 --- a/js/ui/grabHelper.js +++ b/js/ui/grabHelper.js @@ -311,7 +311,8 @@ const GrabHelper = new Lang.Class({ if (hadFocus) { let poppedGrab = poppedGrabs[0]; - _navigateActor(poppedGrab.savedFocus); + if (poppedGrab.savedFocus) + poppedGrab.savedFocus.grab_key_focus(); } },